#!/bin/sh

ERTM_OVERRIDE="/etc/modprobe.d/99-xpadneo-bluetooth.conf"

[ -L "${ERTM_OVERRIDE}" ] || { echo "Uninstalling ERTM override..."; rm -f "${ERTM_OVERRIDE}"; }

echo "Uninstalling modalias database..."
rm -f /etc/modprobe.d/xpadneo.conf

echo "Uninstalling udev rules..."
rm -f /etc/udev/rules.d/98-xpadneo.rules

echo "Reloading udev..."
udevadm control --reload
